The Sun consists of various layers. In its inner core, nuclear fusion reactions take place, generating energy.